package gov.fnal.mcginnis.fitstest;


import java.io.IOException;

import nom.tam.fits.FitsException;

/**
 * @author mcginnis
 *
 */
public class MyFitsTest 
{

	/**
	 * @param args
	 */
	public static void main(String[] args) 
	{
		System.out.println("Hi There");
		try
		{
			PixieImage pi = new PixieImage("NZ-g3-crop.fit");
			double[][] pix = pi.getPix();
			for (int ii = 0; ii <pi.getRowCount(); ++ii) 
				pix[ii][ii] = 1000.0;
			pi.writeToFitsFile("test_image.fit");
			pi = null;
			pi = new PixieImage("NZ-g3-crop.fit", 64, 64, 128, 128); 
			pi.writeToFitsFile("test_image2.fit");
			
			System.out.println(PixieImage.getRowCount("NZ-g3-crop.fit"));
		}
		catch (FitsException fitsexception)
		{
			System.out.println("Fits Problems");
		}
		catch (IOException ioexception)
		{
			System.out.println("Fits Problems");
		}


	}

}
